package com.oc.ui.button;

import java.util.Hashtable;

import net.rim.device.api.system.Bitmap;

public class ResourceManager {

	private static ResourceManager instance = new ResourceManager();
	public static ResourceManager getInstance(){
		return instance;
	}
	
	public ResourceManager(){
		
	}
	
	private Hashtable resources = new Hashtable();
	
	public Bitmap getBitmapResource(String uri)
	{
		if(resources.containsKey(uri)){
			return (Bitmap)resources.get(uri);
		} else {
			Bitmap bmp = Bitmap.getBitmapResource(uri);
			if(bmp != null){
				resources.put(uri, bmp);
			}
			return bmp;
		}
		
	}
	
   
}
